package com.lzjy.tw.composedemo.repository

import android.content.Context
import com.lzjy.tw.composedemo.domain.model.TestModel
import com.lzjy.tw.composedemo.domain.repository.TestRepository
import com.lzjy.tw.composedemo.repository.impl.INoteRepository
import kotlinx.coroutines.flow.Flow
import kotlinx.coroutines.flow.flow

class NoteRepository(val context: Context, private val testRepository: TestRepository) :
    INoteRepository {
    override suspend fun getNote(owner_id: Int) = testRepository.query(owner_id)
    override suspend fun getAllNote(): Flow<List<TestModel>> = testRepository.queryAll()
    override suspend fun insert(testModel: TestModel) = testRepository.insert(testModel)

    override suspend fun requestUrl(params: String): Flow<String> = flow {
        // okhttp
    }
}